www.gusucode.com > 落叶冰点万能企业网站内容管理系统 V9.1 > 落叶冰点万能企业网站内容管理系统 V9.1\code\admin\adminLabel\D_chk_add_custom_c_asp_lable.asp
<% '************************************************************** ' 新动软网站管理系统 ' 官方网站: http://www.aspcpu.com ' 系统作者: 阮丁远(网名:天下程序) ' Copyright 新动软网站管理系统 版权所有 '************************************************************** %> <html> <meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> <LINK href="../css.css" type=text/css rel=stylesheet> <% dir_set="../../" %> <!--#include file=../../inc/conn.asp--> <!--#include file=../../inc/Functionb.asp--> <!--#include file=../../inc/ajaxLIB.asp--> <!--#include file=../inc/checkadmin2.asp--> <!--#include file=../../inc/functionFiless.asp--> <!--#include file=../../inc/ND_class_function.asp--> <% AJAXshowLoader() %> <% if find_dataw("qitashezhi123","0",7)<>"1" and qx_if_max=0 then response.redirect "../D_suodinguser.asp" end if %> <% session("newdsoft_selct_a_lable_bef_haved")="" set filea=new Cls_FSO fpath=request("fpath") bname=trim(request("bnm")) cont=request("Content") bname_err=0 if bname="" then bname_err=1 end if Dim regEx Set regEx = New RegExp ' 建立正则表达式。 regEx.Pattern = "^[A-Za-z0-9_]+$" ' 设置模式。 regEx.IgnoreCase = False ' 设置是否区分大小写。 retVal = regEx.Test(bname) ' 执行搜索测试。 If retVal<>true Then bname_err=1 End If if bname_err=1 then %> <script language=javascript> alert("标签名为空 或者 不是字母+数字及_号的组合"); history.go(-1); </script> <% response.end else bname1="my_b_"&bname bname="my_b_"&bname&".asp" if filea.ReportFileStatus(server.mappath("../../Label/custom_Label/"&fpath&bname))=1 then %> <script language=javascript> alert("此目录有同名标签文件存在,无法添加"); history.go(-1); </script> <% else params_str="" for iit=1 to cint(request("params_len")) if trim(request("c"&cstr(iit)))<>"" then sss1=replace(replace(trim(request("c"&cstr(iit))),",",""),"|","") sss1=replace(replace(sss1,chr(34),"”"),"'","‘") sss2=replace(replace(trim(request("s"&cstr(iit))),",", "," ),"|","") sss2=replace(replace(sss2,chr(34),"”"),"'","‘") '--------------v2 sss3=replace(replace(trim(request("g"&cstr(iit))),",", "," ),"|","") params_str=params_str&sss1&","&sss2&","&sss3&"|" '--------------v2 end if next if params_str<>"" then params_str=left(params_str,len(params_str)-1) end if beizhuz=replace_asp(trim(request("lbsm"))) par=split(params_str,"|") '----h2--------- yooo=0 yooo2=0 for iiii=0 to ubound(par) sss33=split(par(iiii),",") sss3=sss33(0) for iiiii=0 to ubound(par) sss44=split(par(iiiii),",") sss4=sss44(0) if sss3=sss4 and cint(iiiii)<>cint(iiii) then yooo=1 yooo2=1 end if next next errhhhtd=0 htmledxa=cstr(replace_asp(request("htmledxa"))) htmledxb="" for iit1=1 to cint(request("params_lenb")) if trim(request("sc"&cstr(iit1)))<>"" and trim(request("sd"&cstr(iit1)))<>"" then sss1=request("sc"&cstr(iit1)) sss2=request("sd"&cstr(iit1)) if instr(1,sss1,"|",1)<>0 or instr(1,sss1,":",1)<>0 or instr(1,sss1,"'",1)<>0 or instr(1,sss1,chr(34),1)<>0 or instr(1,sss1,",",1)<>0 then errhhhtd=1 yooo=1 exit for end if if instr(1,sss2,"|",1)<>0 or instr(1,sss2,":",1)<>0 or instr(1,sss2,"'",1)<>0 or instr(1,sss2,chr(34),1)<>0 or instr(1,sss2,",",1)<>0 then errhhhtd=1 yooo=1 exit for end if htmledxb=htmledxb&sss1&"$123$121$accndcpu232$321$"&sss2&"$123$121$aspndcpu232$321$" end if next if htmledxb<>"" then htmledxb=left(htmledxb,len(htmledxb)-len("$123$121$aspndcpu232$321$")) end if '----end h2--------- if yooo=1 then '----h3--------- if yooo2=1 then %> <script language=javascript> alert("发现参数列表中有同名参数,必须每个参数都不同名字!"); history.go(-1); </script> <% response.end end if if errhhhtd=1 then %> <script language=javascript> alert("发现 本标签生成html静态页时的选项2 里填写的某个项的 开始asp代码的自定义开始标记 或 结束asp代码的自定义结束标记 里含以下的一个或多个不允许出现的字符:\n\n \" \' \, \: \| "); history.go(-1); </script> <% response.end end if '----end h3--------- end if 'asc(60)=<,asc(37)=%,chr(13)=enter,chr(62)=> ext1=chr(60)&chr(37)&"'$start_ext_newDsoft 以下系统生成,勿删!"&vbcrlf&"'$newDsoft_label_type$:"&"asp_label"&"$end_newDsoft_label_type$"&vbcrlf ext1=ext1&"'$newDsoft_label_name$:"&bname1&"$end_newDsoft_label_name$"&vbcrlf ext1=ext1&"'$newDsoft_label_sql$:"&" "&"$end_newDsoft_label_sql$"&vbcrlf ext1=ext1&"'$newDsoft_label_params$:"¶ms_str&"$end_newDsoft_label_params$"&vbcrlf ext1=ext1&"'$newDsoft_label_fenye_num$:"&" "&"$end_newDsoft_label_fenye_num$"&vbcrlf ext1=ext1&"'$newDsoft_label_beizhu$:"&beizhuz&"$end_newDsoft_label_beizhu$"&vbcrlf ext1=ext1&"'$newDsoft_is_sys_label$:"&"0"&"$end_newDsoft_is_sys_label$"&vbcrlf ext1=ext1&"'$newDsoft_other_params$:"&"htmledxa:"&htmledxa&"|htmledxb:"&htmledxb&"$end_newDsoft_other_params$"&vbcrlf ext1=ext1&"'$end_ext_newDsoft"&chr(37)&chr(62)&vbcrlf&vbcrlf&vbcrlf&vbcrlf if yooo<>1 then if filea.ReportFileStatus(server.mappath("../../Label/custom_Label/"&fpath&bname))=1 then %> <script language=javascript> alert("有重名标签文件存在!"); self.location="D_admin_custom_label.asp?fpath=<%=fpath%>"; </script> <% else call createfile("../../Label/custom_Label/"&fpath&bname,ext1&cont,1) '--------------------------add1 cont11=loadfile("../../Label/custom_Label/"&fpath&bname) call get_info_array_from_label_file_content(cont11) set rs4aa=server.CreateObject("adodb.recordset") rs4aa.open "select * from ND_label_cache where lcase(label_name)='"&nd1_l_name&"'",conn,1,1 set rs4=server.CreateObject("adodb.recordset") if not rs4aa.eof then rs4.open "select * from ND_label_cache where lcase(label_name)='"&nd1_l_name&"'",conn,1,3 else rs4.open "select * from ND_label_cache",conn,1,3 rs4.addnew end if rs4("label_code")=nd1_label_code rs4("label_name")=nd1_l_name rs4("label_full_path_name")=trim("Label/custom_Label/"&fpath&bname) rs4("label_params")=nd1_label_params rs4("label_type")=nd1_label_type rs4("label_sql")=nd1_label_sql rs4("label_fenye_num")=nd1_label_fenye_num rs4("label_beizhu")=nd1_label_beizhu rs4("is_sys_label")="0" rs4("label_other_params")=nd1_other_params rs4.update rs4.close set rs4=nothing '--------------------------add1 %> <script language=javascript> alert("添加成功!"); self.location="D_admin_custom_label.asp?fpath=<%=request("fpath")%>"; </script> <% end if end if end if end if %> <% AJAXcloseLoader() %> </html>